/*
 * @Description: 
 * @Autor: lds
 * @LastEditors: lds
 */
import { createWebHistory, createRouter,RouteRecordRaw,createWebHashHistory } from "vue-router";
const routes: Array<RouteRecordRaw> = [
    {
        path: '/login',
        name: 'Login',
        meta: {
            title: '登录',
            keepAlive: true,
            requireAuth: false
        },
        component: () => import('@/pages/login/index.vue')
    },
    {
        path: '/',
        name: 'Home',
        meta: {
            title: '首页',
            keepAlive: true,
            requireAuth: true
        },
        component: () => import('@/pages/home/index.vue')
    },
    {
        path: '/test',
        name: 'Test',
        meta: {
            title: '测试pinia',
            keepAlive: true,
            requireAuth: false
        },
        component: () => import('@/pages/testPage/pinia-demo.vue')
    },
    {
        path: '/testB',
        name: 'TestB',
        meta: {
            title: '测试vueUse',
            keepAlive: true,
            requireAuth: false
        },
        component: () => import('@/pages/testPage/vueUse.vue')
    },
    {
        path: '/testC',
        name: 'TestC',
        meta: {
            title: '测试scss',
            keepAlive: true,
            requireAuth: false
        },
        component: () => import('@/pages/testPage/scssTest.vue')
    },
    {
        path: '/testD',
        name: 'TestD',
        meta: {
            title: '测试scss',
            keepAlive: true,
            requireAuth: false
        },
        component: () => import('@/pages/testPage/fetchTest.vue')
      
    },
   
]

const router = createRouter({
    history: createWebHashHistory(),
    routes
});
export default router;
